package cn.bearspark.like.provider.dao.key;

import cn.bearspark.framework.redis.starter.key.RedisKeyBuilder;
import org.springframework.stereotype.Component;

/**
 * 点赞评论缓存的键的构造器
 *
 * @author f
 */
@Component
public class CommentLikeBufferKeyBuilder extends RedisKeyBuilder {

    /**
     * 用户点赞评论的 ZSet 的缓存的键的前缀
     */
    private static final String USER_COMMENT_LIKE_ZSET = "userCommentLikeZSet";

    public String buildUserLikeZSetKey(long userId) {
        return super.getPrefix() + USER_COMMENT_LIKE_ZSET + super.getSplitItem() + userId;
    }
}
